﻿using System;
using System.Collections;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Linq;

public partial class PostNotice : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
        NewsDataClassesDataContext dc = new NewsDataClassesDataContext();
        var OtherInfos = from otherInfo in dc.OtherInfos
                         where otherInfo.OtherInfo_id.Equals("1") && otherInfo.isPublished.Equals(1)
                         select new
                         {
                             title = otherInfo.Title,
                             content = otherInfo.Content
                         };

        foreach (var otherInfo in OtherInfos)
        {
            Title_Label.Text = Convert.ToString(otherInfo.title);
            Literal_Text.Text = Convert.ToString(otherInfo.content);
        }
        dc.Dispose();
    }
}
